package _99练习;

public class Calc {
	private float result = 0;

	public Calc() {

	}

	public Calc(float result) {
		this.result = result;
	}

	public float getResult() {
		return result;
	}

	public void setResult(float result) {
		this.result = result;
	}

	public void print() {
		System.out.println(result);
	}

	public void add(float result) {// ＋
		this.result += result;
	}

	public void sub(float result) {// -
		this.result -= result;
	}

	public void mul(float result) {// ×
		this.result *= result;
	}

	public void div(float result) {// ÷
		this.result /= result;
	}

	public void clear() {
		result = 0;
	}
}
